package com.lin.zoo.view;

import javax.swing.*;

public class FeederPage extends JPanel{

    private JButton rePark =new JButton("管理园区信息");
    //修改所管理的园区信息
    private JButton vPark =new JButton("查看园区信息");
    //查看管理的园区信息
    private JButton reAnimal =new JButton("修改动物信息");
    //修改动物信息
    private JButton reActivity=new JButton("管理活动信息");


    public JButton getRePark() {return rePark;}

    public void setRePark(JButton rePark) {this.rePark = rePark;}

    public JButton getVPark() {return vPark;}

    public void setVPark(JButton vPark) {this.vPark = vPark;}

    public JButton getReAnimal() {return reAnimal;}

    public void setReAnimal(JButton reAnimal) {this.reAnimal = reAnimal;}

    public JButton getReActivity() {
        return reActivity;
    }

    public void setReActivity(JButton reActivity) {
        this.reActivity = reActivity;
    }

    public void createAndShowGUI() {

        JFrame frame = new JFrame("饲养员界面");
        frame.setVisible(true);
        frame.setSize(700,530);

        frame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
        // 显示窗口
        frame.setResizable(false);
        //固定窗口大小不被修改
        frame.setLocationRelativeTo(null);
        //窗口处于中央

        init();
        frame.setLayout(null);
        frame.add(rePark);
        frame.add(reAnimal);
        frame.add(vPark);
        frame.add(reActivity);
    }
    private void init(){
        //需要700*500空间
        rePark.setSize(200,100);
        rePark.setLocation(100,100);

        reAnimal.setSize(200,100);
        reAnimal.setLocation(400,100);

        vPark.setSize(200,100);
        vPark.setLocation(100,300);

        reActivity.setSize(200,100);
        reActivity.setLocation(400,300);
    }
}
